<template>
  <div>
    <a-radio-group
      v-if="materialCategoryOptions.length > 0"
      :options="materialCategoryOptions"
      v-model:value="modelValue"
      v-bind="$attrs"
      @change="emit('change')"
    ></a-radio-group>
    <div v-else class="text-gray-400">没有数据</div>
  </div>
</template>

<script setup lang="ts">
import { materialCategoryOptions, getMaterialCategoryOptions } from '@/api/modules/utils/dict.data';
const emit = defineEmits(['change']);
const modelValue = defineModel('modelValue');

onMounted(() => {
  getMaterialCategoryOptions();
});
</script>

<style lang="scss" scoped></style>
